<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>v-show</title>
    <script src="https://cdn.jsdelivr.net/npm/vue@2.6.14/dist/vue.js"></script>
</head>
<body>
    <div id="box">
        <h1>抢座位</h1>
        <!-- v-show使用的是CSS的属性display来进行渲染的，控制dom节点的显示与否 -->
        <h3 v-show="flag1">1号座</h3>
        <h3 v-show="flag2">2号座</h3>
        <h3 v-show="flag3">3号座</h3>
    </div>
</body>
<script>
    const vm = new Vue({
        //该节点内可以使用vue组件
        el:"#box",
        data(){
            return{
               flag1:true,
               flag2:false,
               flag3:true,
            }
        }
    });
</script>
</html>